package com.zch.rpc.client;


import com.zch.rpc.client.interfaces.HelloService;

public class RpcConsumer {
    public static void main(String[] args) throws Exception {
        //获取接口的代理对象
        HelloService service = RpcFramework.refer(HelloService.class, "127.0.0.1", 20881);
        System.out.println(service.getClass().getName());
        String hello = service.hello("World" );
        System.out.println(hello);
      /*  for (int i = 0; i < Integer.MAX_VALUE; i ++) {
            String hello = service.hello("World" + i);
            System.out.println(hello);
            //Thread.sleep(1000);
        }*/
    }
}
